<template>
  <div>
    <el-space size="large">
      <el-button type="primary" :icon="RefreshRight" plain @click="() => emit('reload')">刷新</el-button>
      <el-button type="primary" :icon="Plus" plain @click="() => emit('add')">新增</el-button>
      <el-popconfirm :width="190" placement="top-end" title="确定要删除模块吗?" @confirm="() => emit('del')">
        <template #reference>
          <el-button type="danger" :icon="Delete" plain>删除</el-button>
        </template>
      </el-popconfirm>

    </el-space>
  </div>
</template>

<script setup lang="ts">
import { Plus, Delete, RefreshRight } from '@element-plus/icons-vue';

const emit = defineEmits<{
  (e: 'reload'): void
  (e: 'add'): void
  (e: 'del'): void
}>()

</script>

<style scoped></style>
